﻿<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML xmlns="http://www.w3.org/1999/xhtml">
<HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<TITLE> <? echo $title;?> </TITLE>
<base href="<?php echo base_url() ?>" />
<LINK href="images/default.css" type="text/css" rel=stylesheet>
<SCRIPT src="js/common.js" type="text/javascript"></SCRIPT>
<SCRIPT src="js/jquery.min.js" type="text/javascript"></SCRIPT>
<script src="js/jquery.form.js" type="text/javascript"></script>
<SCRIPT type="text/javascript">
   function collapse_change(menucount) {
       $("#list_"+menucount).toggle() ;
}
</SCRIPT>
<SCRIPT type="text/javascript">
<!--
$(function(){
	$('#msgs').hide();
    var options = {
		target:     '#msgs', //结果显示目标
    	url:        '<?php echo site_url("admin/updateOrg1"."/".$org1['org1_id']) ?>', //action目标
		beforeSubmit: function(){

		    			if($('#name').val()==''){
							$('#msgs').html("<span class=\"about_content_title\">[一级组织名称]不能为空!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('#name').focus();
							return false;
						}

						if($('#fzr').val()==''){
							$('#msgs').html("<span class=\"about_content_title\">[负责人]不能为空!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('fzr').focus();
							return false;
						}
	                   if($('#email').val()==''){
							$('#msgs').html("<span class=\"about_content_title\">[电子邮箱]不能为空!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('#email').focus();
							return false;
						}
						if($('#tel').val()==''){
							$('#msgs').html("<span class=\"about_content_title\">[联系电话]不能为空!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('#tel').focus();
							return false;
						}


                        if(isEmail($('#email').val())){
							$('#msgs').html("<span class=\"about_content_title\">邮箱格式不正确!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('#email').val("");
                            $('#email').focus();
							return false;
						}
                         if(isTel($('#tel').val())){
							$('#msgs').html("<span class=\"about_content_title\">联系电话格式不正确!</span>");
							$('#msgs').show(1000);
							$('#msgs').hide(3000);
                            $('#tel').val("");
                            $('#tel').focus();
							return false;
						}
                        $("#submit").attr('value','正在提交...');
                        $(":input") .attr('disabled', true) ;
						$('#msgs').html("<img src=\"images/loading.gif\" /><span class=\"about_content_title\"> 资料正在提交，请稍候。。。</span>");
    					$('#msgs').show(1000);
					},
    	success:    function() {
                       $(":input") .attr('disabled', false);
                       $("#submit").attr('value','保 存');
                       $('#msgs').show(3000);


    				}
    };
    $('#myform').ajaxForm(options);
});
-->
</SCRIPT>
</HEAD>
<BODY topMargin=10>
<TABLE cellSpacing=6 cellPadding=2 width="100%" border=0>
  <TBODY>
  <TR>
    <TD>
      <TABLE class=guide cellSpacing=0 cellPadding=0 width="100%" border=0>
        <TBODY>
        <TR>
          <TD><A href="<?php echo site_url("admin/info"); ?>" target="main">后台首页</A>&nbsp;» 编辑一级组织</TD>
        </TR></TBODY></TABLE>
      <BR>
       <FORM id="myform" name="myform" method="post">
        <table class="tableborder" width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr class="header">
          <td colspan="2">编辑一级组织 </td>
        </tr>
        <tr>
          <td width="100">一级组织名称：            </td>
          <td><input type="text" size="40" name="name" id="name" value="<? if(isset($org1)){echo $org1['org1_name'];}?>" ></td>
        </tr>
        <tr>
          <td>负责人：            </td>
          <td><input type="text" size="40" name="fzr" id="fzr" value="<? if(isset($org1)){echo $org1['org1_fzr'];}?>" ></td>
        </tr>
        <tr>
          <td>电子邮箱：           </td>
         <td><input type="text" size="40" name="email" id="email" value="<? if(isset($org1)){echo $org1['org1_email'];}?>" ></td>
        </tr>
        <tr>
          <td>联系号码：           </td>
         <td><input type="text"size="40" name="tel" id="tel" value="<?  if(isset($org1)){echo $org1['org1_tel'];}?>" ></td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td><input id="submit" type=submit value="保 存" name=submit>&nbsp;&nbsp;&nbsp;&nbsp;
              <input type="button" value="全部清除" name="con" onclick=" $('#myform').clearForm();$('#name').focus()">&nbsp;&nbsp;&nbsp;&nbsp;
              <input type="button" value="刷 新" name="con" onclick="window.location.reload() ;">&nbsp;&nbsp;&nbsp;&nbsp;
              <input type="button" value="返 回" name="con" onclick=" javascript:history.go(-1) ;">
     
         </td>
        </tr>
        <tr>
          <td>  </td>
          <td > <div id="msgs" style="margin-top:12px;margin-bottom:5px;font-size:13px;color: #C62E25;font-weight:bold;">info</div>        </td>
        </tr>
      </table>
      </FORM>
     </TD>
     </TR>
    </TBODY>
   </TABLE><BR><BR>
      <br/><br/>
      <DIV class=footer>
        <HR width="80%" color=#9db3c5 noShade SIZE=0>
         Powered by <? echo $copyright ?>  <em>,</em> <B><A style="COLOR: #666" href="<? echo base_url() ?>" target="_blank"><? echo $version;?>.</A></B>
      </DIV>
</BODY></HTML>
